<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>拉萨市财政局投资评审管理系统  </title>
    <link rel="stylesheet" href="css/style.css">
    <script src="js/jquery-1.10.2.min.js"></script>
</head>
<body>
<!--main-header start-->
<div class="main-header">
    <div class="w-1200 clearfix">
        <div class="header-logo fl"><a href=""><img src="images/logo.png"></a> </div>
        <!--header-person start-->
        <div id="head_login"></div>
        <script type="text/javascript">
          
          $("#head_login").load("login_common.html");
        </script>
        <!--header-person end-->
        <!--header-nav start-->
        <div class="header-nav fr">
            <ul class="nav">
                <li><a href="/ownerindex.html">在审核项目</a> </li>
                <li><a href="/ownerindex2.html">已审核项目</a> </li>
                <span id="art"></span>
                <script>$("#art").load("artcommon.html")</script>
            </ul>
        </div>
        <!--header-nav end-->
    </div>
</div>
<!--main-header end-->
<!--scan-container start-->
<div class="scan-container w-1200" id="mainbox">
    <!--scan-step start-->
    <div class="scan-step clearfix">
        <div class="scan-step-hd fl">项目进度</div>
        <div class="scan-step-bd">
            <div class="step-num">
                <span class="circle">1</span>
                <p>资料准备</p>
            </div>
            <div class="step-num">
                <span class="circle">2</span>
                <p>预审中</p>
            </div>
            <div class="step-num">
                <span class="circle">3</span>
                <p>评审中</p>
            </div>
            <div class="step-num">
                <span class="circle">4</span>
                <p>复核中</p>
            </div>
            <div class="step-num">
                <span class="circle">5</span>
                <p>定审中</p>
            </div>
            <div class="step-num">
                <span class="circle">6</span>
                <p>完结</p>
            </div>
        </div>
    </div>
    <!--scan-step end-->
    <!--scan-main start-->
    <div class="scan-main">
        <div id="sm"></div>
        <script>$("#sm").load("common-iteminfo.html")</script>
        <!--scan-box end-->
        <!--scan-box start-->
        <div class="scan-box" id="filebox">
            <script>
                $("#filebox").load("filedetail.html");
            </script>
        </div>
        <!--scan-box end-->
       

    </div>
    <!--scan-main end-->
    <!--scan-main start-->
   
    <div id="reject"></div> 
</div>
<!--scan-container end-->


<script src="js/auth.js"></script>

<script type="text/javascript">
    
    var id=getQueryString("id");
    console.log(id);
    $.get(HTTP_HOST+"api/Owner/detail?his=his&id="+id,function(res){

            if (res.code == 200) {
                item = res.result.item;
                filllogs(res.result.logs);
                    $("#xmbd").html(item.xmbd);
                    $("#xmlxr").html(item.contactor);
                    $("#address").html(item.address);
                    $("#name").html(item.name);
                    $("#type").html(item.type);
                    $("#owner").html(item.owner);
                    $("#industry").html(item.industry);
    
                    $("#lxwh").html(item.lxnumber);
                    $("#yjbh").html(item.yjbh);
    
                    $("#wtdw").html(item.wtdw);
                    $("#wtdwlxr").html(item.wtdwcontactor);
                    $("#wtdwlxrdh").html(item.wtdwcontactorphone);
                    $("#cash").html(item.cash);

                    var index = getstat(item.status);
                    $(".step-num").each(function(k,obj){
                        if(k<=index){
                            $(obj).addClass("on");
                        }  
                    });






                    if(item.status == 4){
                        var act=` <div class="scan-main">
        <!--scan-box start-->
        <div class="scan-box">
            <div class="scan-box-tit">复合意见</div>
            <div class="scan-opinion-text">
                <div class="text-bor">
                    <textarea rows="5"  id="idea"  placeholder="在此输入你对此次项目的具体评审意见"></textarea>
                </div>
            </div>
        </div>
        <!--scan-box end-->
    </div>
    <!--scan-main end-->
    <!--add-bottom start-->
    <div class="add-bottom mar0">
        <button class="login-btn" onclick="pass(1)">审核通过</button>
        <button class="login-btn bor" onClick="pass(0)">驳回申请</button>
    </div>`;
    $(".scan-container").append(act);
                    }
              
    
                }
    
    },'JSON');
    
    

    function pass(res){
        var idea = $("#idea").val();
        if(idea == ""){
            alert("请填写意见 ");
            return  false;
        }
        $.post("/api/Owner/dealitem",{"id":id,"idea":$("#idea").val(),'appres':res},function(res){



            if(res.result.code==200){
                alert("操作成功 ");
                window.location.reload();
            }else{
                alert(res.result.msg);
                return false;
            }


        },'Json');




    }
    
    </script>







</body>
</html>